<?php

	session_start();
	include_once('zoo/snakegrass.php');
	include_once('zoo/mothergoose.php');
	$sg = new snakeGrass();
	if(isset($_GET['action'])){
		$sg->render($_GET['action']);
		echo "Action: ".$_GET['action']."<br>";
	}

?>
<html>
	<head>
		<title>ICS-SAIS</title>
		<link rel="stylesheet" type="text/css" href="css/default.css">
		<?php
			$arr = new array('leftBanner', 'rightBanner', 'rightBody', 'leftBody', 'footer');

			foreach($arr as $x){
				echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"css/".$_SESSION[$x]."\">";
			}
		?>
	</head>
	<body>
		<div id="wrapper">
			<div id="banner">
				<div id="leftBanner"><?php $sg->getPage($_SESSION['leftBanner'])?></div>
				<div id="rightBanner"><?php $sg->getPage($_SESSION['rightBanner'])?></div>
			</div>

			<div id="body">
				<div id="leftBody"><?php $sg->getPage($_SESSION['leftBody'])?></div>
				<div id="rightBody"><?php $sg->getPage($_SESSION['rightBody'])?></div>
			</div>
			<div id="footer"><?php $sg->getPage($_SESSION['footer'])?></div>
		</div>
	</body>
	<script type="text/javascript" src="js/default.js"></script>
</html>